package cc.deng.wubo.minapp.beans;

import org.nutz.dao.DB;
import org.nutz.dao.entity.annotation.*;

import java.io.Serializable;

/**
 * Created by Administrator on 2018/3/17.
 */
@Table("t_user_role")
public class SysUserRole  implements Serializable {
    @Column
    @Id
    @Prev({
            @SQL(db= DB.MYSQL,value = "SELECT IFNULL(MAX(id),0)+1 FROM t_user_role"),
            @SQL(db= DB.ORACLE,value = "SELECT COALESCE(MAX(id),0)+1 FROM t_user_role")
    })
    private Integer id;

    @Column("user_id")
    private Integer userId;


    @Column("role_id")
    private Integer roleId;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public Integer getRoleId() {
        return roleId;
    }

    public void setRoleId(Integer roleId) {
        this.roleId = roleId;
    }
}
